Task References

On this page:

transformation

Purpose

The transformation task allows you to run a JSON Schema Transformation (JST) that has already been loaded into the system. A JST is used to transform data from one set of JSON Schemas to another set of JSON Schemas.

⚠ Refer to the Transformations user guide for additional detail on using JSTs in IAP.

Figure: Run Transformation Task

Transformation Task

Creating a transformation in IAP using the API will require a unique name. This "name" is used when configuring the transformation task (see the Properties section below for more information). The user must populate the Transformation Name field with the "name" provided via the Create API (POST /transformations) or with the Search API (GET /transformations) and then click the corresponding name from the dropdown list. If the transformation in question does not contain a "name", then the "id" value can also be used. At this point, the Incoming Schema(s) section will be discovered and rendered from the transformation.

Properties

Task properties are listed in the table below.

Name Description
Retry Task Toggle switch to enable (open) a settings modal to automatically retry a task. Settings include when to retry, how often, and if there should be a delay between retry attempts. Task retry can also be configured manually within Job Manager. Click the links for more information on Retry Task for Gen 1 workflows and Gen 2 workflows.
Transformation Name This is the name of the transformation in the database. The name can be found by searching for a transformation using the Search API or from the "name" key in the response of the Create API.
Incoming Schema(s) The incoming JSON Schemas associated with the transformation. Each of these schemas require a data binding from either a previous task, job variable, or a static value. Each JST has a different (but not necessarily unique) set of incoming schemas.
Transformation Options The option to extract the output value, use a default value, and validate the input are available on the task. Details for all JST options in workflows are described in the next section.
Task Options The Mask Outgoing Schema option is available on all tasks. It encrypts outgoing variables and displays them as asterisks in Job Manager.


Transformation Options

Transformation options are referenced below.

Name Description
extractOutput This option extracts the output value if the transformation only has one outgoing JSON Schema. For example, a transformation with a single outgoing schema having an "$id" of "fruit" would normally respond as follows: { "fruit": "apple" }, but with the extractOutput option, the response would just be "apple". Additional information can be found at this IAP Release Alert.
Validate Incoming Validates your input. Checks if the input is the correct type and compatible with the enum set of constants in that incoming schema.
Revert to Default Value Enables use of a default keyword.
  • Default values from the incoming schemas will be used whenever a key/incoming data value is not provided.
  • If an outgoing schema has a default value, an incoming schema is assigned to it.
  • If the incoming schema does not have a default defined, then the default for the outgoing schema will be used.
  • If an outgoing schema has a default value defined, and nothing is assigned to it, then the default values will be in the transformation output.


Transformation API Endpoints

Referenced below are the API endpoints associated with the transformation task.

API Endpoint Description Route
searchTransformations Search for transformation documents. GET/transformations
getTransformation Gets a transformation document by ID. GET/transformations/:id
createTransformation Creates a single transformation POST/transformations
updateTransformation Updates a single transformation. PUT/transformations/:id
deleteTransformation Deletes a single transformation document. DELETE/transformations/:id
runTransformation Runs a transformation. POST/transformations/:id
importTransformation Imports a single transformation. POST/transformations/import